<template>
   <el-form :model="formData" label-width="120px">
    <el-form-item label="商品名称">
      <el-input v-model="formData.name" />
    </el-form-item>
    <el-form-item label="商品图片">
      <Tuku v-model="formData.pic"></Tuku>
    </el-form-item>
    <el-form-item>
      <el-button type="primary" @click="onSubmit">添加</el-button>
    </el-form-item>
  </el-form>


</template>
<script setup lang="ts">
import { ref,reactive } from "vue"
import Tuku from "@/components/Tuku.vue";
const formData = reactive({
   name:"华为Meta18",
   pic:"https://devpress.csdnimg.cn/489fad64a62648818eaaebc28e5c8659.jpg"
})

const onSubmit = ()=>{
   console.log(formData);
   
}

</script>